<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui">

<h:head>

	<link type="text/css" rel="stylesheet" href="css/styles.css" />
	<script type="text/javascript">
	 function handleMessage(data) {
			$('.display').html(data);
		}


		function notificationMessage(facesmessage) {
			facesmessage.severity = 'info';
			growl.show([ facesmessage ]);
		}
		
        function start() {  
            statusDialog.show();  
        }  
          
        function stop() {  
            statusDialog.hide();  
        }  
		

	</script>
</h:head>
<h:body>
	<p:layout fullPage="true">
		<p:layoutUnit position="north" size="50">
			<p:panel style="width:250px">
				<p:outputLabel value="Workspace:${workspace.workspace.name}"></p:outputLabel>
			</p:panel>
		</p:layoutUnit>

		<p:layoutUnit position="south" size="50" resizable="true"
			closable="true" collapsible="true">
			<h:outputText value="Fuzzy Clustering." />

			<p:ajaxStatus
				style="width:64px;height:64px;position:fixed;right:5px;bottom:5px">
				<f:facet name="start">
					<p:graphicImage value="images/loading.gif" />
				</f:facet>

				<f:facet name="complete">
					<h:outputText value="" />
				</f:facet>
			</p:ajaxStatus>
		</p:layoutUnit>

		<!--  <p:layoutUnit position="west" size="200" header="Left" resizable="true" closable="true" collapsible="true">  
        <h:outputText value="West unit content." />  
    </p:layoutUnit>  
  
    <p:layoutUnit position="east" size="200" header="Right" resizable="true" closable="true" collapsible="true" effect="drop">  
        <h:outputText value="Right unit content." />  
    </p:layoutUnit>  
   -->
		<p:layoutUnit position="center">
			<!--  <h:form>-->

			<ui:insert name="context">...</ui:insert>
			<ui:insert name="resume"></ui:insert>
			<br></br>
			<ui:insert name="content">...</ui:insert>
			<!-- </h:form> -->

		</p:layoutUnit>

	</p:layout>

	<p:idleMonitor onactive="sessionTimeOutDialog.show();" timeout="600000">
		<p:ajax event="idle" listener="#{workspace.invalidateSession}" />
	</p:idleMonitor>
	<p:dialog header="Session Caducada" widgetVar="sessionTimeOutDialog"
		modal="true" fixedCenter="true" closable="false" width="430"
		visible="false">
		<p:panel style="width:400px">
			<h:outputText
				value="La sesion ha caducado, por favor, presiona recargar para volver a acceder a la aplicacion" />
				<br></br>
			<input id="confirmBackToLogin" type="button" value="Recargar"
				onclick="window.location='#{facesContext.externalContext.requestContextPath}/index.xhtml';"/>
		</p:panel>
	</p:dialog>


</h:body>
</html>